import request from '@/utils/request';
import { other } from './prefix';

const vrstadiumsManage = {
  // 查询全景场馆列表
  getVrstadiums(params) {
    return request.get(other + '/vrstadiums', { params });
  },
  // 创建全景场馆
  setVrstadiums(params) {
    return request.post(other + '/vrstadiums', params);
  },
  // 更新全景场馆
  updVrstadiums(id, params) {
    return request.post(other + '/vrstadiums/' + id, params);
  },
  // 删除全景场馆
  delVrstadiums(id) {
    return request.delete(other + '/vrstadiums/' + id);
  },
  
  // 上传封面图
  setVrstadiumsImage(id, params) {
    return request.post(other + '/vrstadiums/' + id + '?op=upload_file&name=title_page', params);
  },

  
  // 创建场景
  setVrscene(params) {
    return request.post(other + '/vrscene', params);
  },
  // 更新全景场馆
  updVrscene(id, params) {
    return request.post(other + '/vrscene/' + id, params);
  },
  // 删除全景场馆
  delVrscene(id) {
    return request.delete(other + '/vrscene/' + id);
  },
  // 根据id查询场景列表
  getVrscene(params) {
    return request.get(other + '/vrscene', { params });
  },

  // 上传场景图
  setVrimages(id, params) {
    return request.post(other + '/vrscene/' + id + '?op=upload_file&name=image_url', params);
  },
};

export default vrstadiumsManage;


